package com.saer.server.network;

import java.util.concurrent.LinkedBlockingQueue;

public class ExpiringQueue<E> extends LinkedBlockingQueue<E> {

	private static final long serialVersionUID = -4943927451843465599L;

	private int remainigLives = 3;

	public ExpiringQueue(int arg0) {
		super(arg0);
	}

	public synchronized int getRemainigLives() {
		return remainigLives;
	}

	public synchronized void resetRemainigLives() {
		this.remainigLives = 3;
	}

	public synchronized void decRemainigLives() {
		this.remainigLives--;
	}

}
